package com.zjl.aop.proxy;

import org.springframework.aop.framework.ProxyFactory;

/**
 * @Auther: zhuangjl
 * @Date: 2021/12/14 18:49
 */
public class Main {

    public static void main(String[] args) {

        ProxyFactory factory = new ProxyFactory(new SimplePojo());
        factory.addInterface(Pojo.class);
     //   factory.addAdvice(new RetryAdvice());

        Pojo pojo = (Pojo) factory.getProxy();
        // this is a method call on the proxy!
        pojo.foo();
    }
}
